﻿using Diablo3.Services.BattleNet;
using Diablo3.Services.Model.Profiles;
using System;
using System.Collections.Generic;
using System.Linq;
using System.ServiceModel;
using System.ServiceModel.Web;
using System.Text;
using System.Threading.Tasks;

namespace Diablo3.Services
{
    /// <summary>
    /// 
    /// </summary>
    [ServiceContract]
    public interface IDiablo3Service : IDisposable
    {
        #region Methods

        /// <summary>
        /// Gets the profile.
        /// </summary>
        /// <param name="battleTag">The battle tag.</param>
        /// <returns></returns>
        Profile GetProfile(BattleTag battleTag);

        /// <summary>
        /// Gets the profile async.
        /// </summary>
        /// <param name="battleTag">The battle tag.</param>
        /// <returns></returns>
        Task<Profile> GetProfileAsync(BattleTag battleTag);

        /// <summary>
        /// Gets the profile.
        /// </summary>
        /// <param name="battletagName">Name of the battletag.</param>
        /// <param name="battletagCode">The battletag code.</param>
        /// <param name="localization">The localization.</param>
        /// <returns></returns>
        [OperationContract]
        [WebGet(UriTemplate = "api/d3/profile/{battletagName}-{battletagCode}/?local={localization}")]
        Profile GetProfile(string battletagName, string battletagCode, string localization);

        /// <summary>
        /// Gets the profile async.
        /// </summary>
        /// <param name="battletagName">Name of the battletag.</param>
        /// <param name="battletagCode">The battletag code.</param>
        /// <param name="localization">The localization.</param>
        /// <returns></returns>
        [OperationContract]
        Task<Profile> GetProfileAsync(string battletagName, string battletagCode, string localization);

        #endregion
    }
}
